﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace B16_窗体传值
{
    public partial class Form2 : Form
    {
        public delegate void DelText(string str);
        private DelText delText;

        public Form2(DelText del)
        {
            delText = del;
            InitializeComponent();
        }

        private void Button1_Click(object sender, EventArgs e)
        {
            delText(textBox1.Text);
        }
    }
}
